const text = "This is Javascript code, what is javascript?";
const result = text.replace(/javascript/gi, "JavaScript");
console.log(text); // This is Javascript code, what is javascript?
console.log(result); // This is JavaScript code, what is JavaScript?
